<form class="layui-form">
  <div class="layui-form-item">
    <label class="layui-form-label">登录账户</label>
    <div class="layui-input-block">
      <input type="text" name="username" lay-verify="required" placeholder="请输入登录账户" autocomplete="off" class="layui-input">
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">登录密码</label>
    <div class="layui-input-block">
      <input type="text" name="pwd" lay-verify="required" placeholder="请输入登录密码" autocomplete="off" class="layui-input">
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">真实姓名</label>
    <div class="layui-input-block">
      <input type="text" name="name" placeholder="请输入真实姓名" autocomplete="off" class="layui-input">
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">联系电话</label>
    <div class="layui-input-block">
      <input type="text" name="phone" placeholder="请输入联系电话" autocomplete="off" class="layui-input">
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">所属部门</label>
    <div class="layui-input-block">
      <{volist name='department' id='v'}>
      <input type="checkbox" name="department_ids[<{$v['id']}>]" lay-skin="primary" title="<{$v['title']}>" value="<{$v['id']}>" />
      <{/volist}>
    </div>
  </div>
  <div class="layui-form-item">
    <div class="layui-input-block">
      <button class="layui-btn" lay-submit="" lay-filter="form">立即提交</button>
    </div>
  </div>
</form>
<script>
$().ready(function(){
  layui.form.render('checkbox');
});
</script>
